home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Info-Mac 4
/
Info_Mac IV CD-ROM (Pacific HiTech Inc.)(August 1994).iso
/
Science
/
RLaB
/
rlib
/
finite.r
< prev
next >
Wrap
Text File
|
1994-04-25
|
439b
|
18 lines
//----------------------------------------------------------------------
//
// finite
//
// Syntax: a=finite(b)
//
// This routines returns a matrix containing a 1 if the corresponding
// element is finite (i.e., not Inf or NaN) and a 0 if it is either
// Inf or NaN.
//
// Original Author: Jeff Layton
//----------------------------------------------------------------------
finite = function(b)
{
return !(isinf (b) + isnan (b))
};